//
//  DataManager.h
//  HuaWan
//
//  Created by HuaWan  on 2023.
//  Copyright © 2023 HuaWan . All rights reserved.
//

#import <Foundation/Foundation.h>
#import "YTKKeyValueStore.h"
#import "HWTeaModel.h"
#import "HWTypeModel.h"

@interface DataManager : NSObject

#pragma mark - 初始化

- (void)initTable;

- (NSString*)getGuid;

#pragma mark - 添加数据

- (void)addTeaDataWithModel:(HWTeaModel *)model;

- (void)addTypeDataWithModel:(HWTypeModel *)model;

#pragma mark - 查询数据

//获取所有数据
- (NSArray *)getTeaArray;

//获取所有数据
- (NSArray *)getTypeArray;

//查询指定时间数据
- (HWTeaModel *)querTeaDataDicWithDate:(NSString *)date;

#pragma mark - 删除

//删除指定id数据
- (void)deleteTeaDataDicWithteaId:(NSString *)plantId;

+ (instancetype)shareInstance;

#define kDataManager [DataManager shareInstance]

@end
